<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
<html><head><meta name="qrichtext" content="1" /><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><style type="text/css">
p, li { white-space: pre-wrap; }
</style></head><body style=" font-family:'DejaVu Sans'; font-size:11pt; font-weight:400; font-style:normal;">
<p style=" margin-top:0px; margin-bottom:10px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt; font-weight:600;">VBA Excel. Объявление функций в 64-разрядных версиях</span></p>
<p style=" margin-top:0px; margin-bottom:30px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt; font-style:italic;">Объявление функций, созданных для 32-разрядных платформ, в 64-разрядных версиях VBA Excel с помощью оператора Declare и ключевого слова PtrSafe.</span></p>
<p style=" margin-top:32px; margin-bottom:6px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; background-color:#fafafa;"><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt; font-weight:600; color:#333333;">Содержание</span></p>
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a href="https://vremya-ne-zhdet.ru/vba-excel/obyavleniye-funktsiy-v-64-razryadnykh-versiyakh/#Klucevoe_slovo_PtrSafe"><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt; text-decoration: underline; color:#0000ff;">1. Ключевое слово PtrSafe</span></a></p>
<p style=" margin-top:2px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a href="https://vremya-ne-zhdet.ru/vba-excel/obyavleniye-funktsiy-v-64-razryadnykh-versiyakh/#Sreda_razrabotki_VBA_7"><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt; text-decoration: underline; color:#0000ff;">2. Среда разработки VBA 7</span></a></p>
<p style=" margin-top:2px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a href="https://vremya-ne-zhdet.ru/vba-excel/obyavleniye-funktsiy-v-64-razryadnykh-versiyakh/#Obratnaa_sovmestimost"><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt; text-decoration: underline; color:#0000ff;">3. Обратная совместимость</span></a></p>
<p style=" margin-top:2px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a href="https://vremya-ne-zhdet.ru/vba-excel/obyavleniye-funktsiy-v-64-razryadnykh-versiyakh/#Primecanie"><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt; text-decoration: underline; color:#0000ff;">4. Примечание</span></a></p>
<p style=" margin-top:0px; margin-bottom:30px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a name="Klucevoe_slovo_PtrSafe"></a><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt; font-weight:600;">К</span><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt; font-weight:600;">лючевое слово PtrSafe</span></p>
<p style=" margin-top:0px; margin-bottom:30px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt;">Если в 64-разрядной среде разработки VBA Excel объявить следующую функцию с помощью оператора Declare:</span></p>
<p style="-qt-paragraph-type:empty; margin-top:12px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; line-height:15px; font-family:'Verdana,Arial,sans'; font-size:7.8pt; font-weight:496; background-color:#fdfdfd;"><br /></p>
<table border="0" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px;" cellspacing="2" cellpadding="0">
<tr>
<td bgcolor="#dfefff" style=" vertical-align:top; padding-left:0; padding-right:0; padding-top:0; padding-bottom:0;">
<p align="center" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a name="urvanov-syntax-highlighter-64fa30b77f4de410853142"></a><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#5499de;">1</span></p></td>
<td style=" vertical-align:top; padding-left:0; padding-right:0; padding-top:0; padding-bottom:0;">
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a name="urvanov-syntax-highlighter-64fa30b77f4de410853142-1"></a><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">P</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">rivate</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Declare</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Function</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">MultiByteToWideChar </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Lib</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#008000;">&quot;kernel32.dll&quot;</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">(</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">CodePage </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Long</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">,</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">dwFlags </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Long</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">,</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">lpMultiByteStr </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">String</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">,</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">cchMultiByte </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Long</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">,</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">lpWideCharStr </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Long</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">,</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">cchWideChar </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Long</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">)</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Long</span></p></td></tr></table>
<p style=" margin-top:0px; margin-bottom:30px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a name="aswift_1_host"></a><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt;">т</span><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt;">о она будет выделена красным цветом, а при запуске любой процедуры в этом модуле, будет сгенерирована ошибка компиляции:</span></p>
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:30px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'MS Shell Dlg 2'; font-size:7.8pt;"><br /></p>
<p style=" margin-top:0px; margin-bottom:30px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt;">Чтобы данная функция была объявлена корректно в 64-разрядной версии VBA Excel, необходимо после оператора Declare вставить ключевое слово PtrSafe:</span></p>
<p style="-qt-paragraph-type:empty; margin-top:12px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; line-height:15px; font-family:'Verdana,Arial,sans'; font-size:7.8pt; font-weight:496; background-color:#fdfdfd;"><br /></p>
<table border="0" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px;" cellspacing="2" cellpadding="0">
<tr>
<td bgcolor="#dfefff" style=" vertical-align:top; padding-left:0; padding-right:0; padding-top:0; padding-bottom:0;">
<p align="center" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a name="urvanov-syntax-highlighter-64fa30b77f4ee839807772"></a><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#5499de;">1</span></p></td>
<td style=" vertical-align:top; padding-left:0; padding-right:0; padding-top:0; padding-bottom:0;">
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a name="urvanov-syntax-highlighter-64fa30b77f4ee839807772-1"></a><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">P</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">rivate</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Declare</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">PtrSafe </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Function</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">MultiByteToWideChar </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Lib</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#008000;">&quot;kernel32.dll&quot;</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">(</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">CodePage </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Long</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">,</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">dwFlags </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Long</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">,</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">lpMultiByteStr </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">String</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">,</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">cchMultiByte </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Long</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">,</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">lpWideCharStr </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Long</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">,</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">cchWideChar </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Long</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">)</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Long</span></p></td></tr></table>
<p style=" margin-top:0px; margin-bottom:30px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a name="Sreda_razrabotki_VBA_7"></a><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt; font-weight:600;">С</span><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt; font-weight:600;">реда разработки VBA 7</span></p>
<p style=" margin-top:0px; margin-bottom:30px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt;">Операторы Declare с ключевым словом PtrSafe представляют собой рекомендованный синтаксис для среды разработки VBA 7. Функции, объявленные таким образом, корректно работают как на 32-битных, так и на 64-битных платформах.</span></p>
<p style=" margin-top:0px; margin-bottom:30px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt;">Тип переменных, объявленных как Long, рекомендуется заменить на LongPtr, который в 32-разрядных системах интерпретируется как Long, а в 64-разрядных — как </span><a href="https://vremya-ne-zhdet.ru/vba-excel/tipy-dannykh/"><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt; text-decoration: underline; color:#0000ff;">LongLong</span></a><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt;">:</span></p>
<p style="-qt-paragraph-type:empty; margin-top:12px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; line-height:15px; font-family:'Verdana,Arial,sans'; font-size:7.8pt; font-weight:496; background-color:#fdfdfd;"><br /></p>
<table border="0" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px;" cellspacing="2" cellpadding="0">
<tr>
<td bgcolor="#dfefff" style=" vertical-align:top; padding-left:0; padding-right:0; padding-top:0; padding-bottom:0;">
<p align="center" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a name="aswift_2_host"></a><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#5499de;">1</span></p></td>
<td style=" vertical-align:top; padding-left:0; padding-right:0; padding-top:0; padding-bottom:0;">
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a name="urvanov-syntax-highlighter-64fa30b77f4f8640349393-1"></a><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">P</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">rivate</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Declare</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">PtrSafe </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Function</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">MultiByteToWideChar </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Lib</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#008000;">&quot;kernel32.dll&quot;</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">(</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">CodePage </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#002d7a;">LongPtr</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">,</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">dwFlags </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#002d7a;">LongPtr</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">,</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">lpMultiByteStr </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">String</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">,</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">cchMultiByte </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#002d7a;">LongPtr</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">,</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">lpWideCharStr </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#002d7a;">LongPtr</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">,</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">cchWideChar </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#002d7a;">LongPtr</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">)</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#002d7a;">LongPtr</span></p></td></tr></table>
<p style=" margin-top:0px; margin-bottom:30px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a name="Obratnaa_sovmestimost"></a><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt; font-weight:600;">О</span><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt; font-weight:600;">братная совместимость</span></p>
<p style=" margin-top:0px; margin-bottom:30px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt;">Чтобы обеспечить обратную совместимость процедур (Function, Sub) в VBA7 и более ранних версиях офисных программ, используйте следующую структуру:</span></p>
<p style="-qt-paragraph-type:empty; margin-top:12px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; line-height:15px; font-family:'Verdana,Arial,sans'; font-size:7.8pt; font-weight:496; background-color:#fdfdfd;"><br /></p>
<table border="0" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px;" cellspacing="2" cellpadding="0">
<tr>
<td bgcolor="#dfefff" style=" vertical-align:top; padding-left:0; padding-right:0; padding-top:0; padding-bottom:0;">
<p align="center" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a name="urvanov-syntax-highlighter-64fa30b77f4fd487876650"></a><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#5499de;">1</span></p>
<p align="center" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; background-color:#c8e1fa;"><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#317cc5; background-color:#c8e1fa;">2</span></p>
<p align="center" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#5499de;">3</span></p>
<p align="center" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; background-color:#c8e1fa;"><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#317cc5; background-color:#c8e1fa;">4</span></p>
<p align="center" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#5499de;">5</span></p></td>
<td style=" vertical-align:top; padding-left:0; padding-right:0; padding-top:0; padding-bottom:0;">
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a name="urvanov-syntax-highlighter-64fa30b77f4fd487876650-1"></a><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#000000;">#</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">If</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">VBA7 </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Then</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span></p>
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; background-color:#f7f7f7;"><a name="urvanov-syntax-highlighter-64fa30b77f4fd487876650-2"></a><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;">   </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Declare</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">PtrSafe </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Function</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">MultiByteToWideChar </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Lib</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#008000;">&quot;kernel32.dll&quot;</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">(</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">CodePage </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#002d7a;">LongPtr</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">,</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">dwFlags </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#002d7a;">LongPtr</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">,</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">lpMultiByteStr </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">String</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">,</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">cchMultiByte </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#002d7a;">LongPtr</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">,</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">lpWideCharStr </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#002d7a;">LongPtr</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">,</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">cchWideChar </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#002d7a;">LongPtr</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">)</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#000000;">LongPtr</span></p>
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a name="urvanov-syntax-highlighter-64fa30b77f4fd487876650-3"></a><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#000000;">#</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Else</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span></p>
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; background-color:#f7f7f7;"><a name="urvanov-syntax-highlighter-64fa30b77f4fd487876650-4"></a><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;">   </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Declare</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Function</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">MultiByteToWideChar </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Lib</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#008000;">&quot;kernel32.dll&quot;</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">(</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">CodePage </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Long</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">,</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">dwFlags </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Long</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">,</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">lpMultiByteStr </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">String</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">,</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">cchMultiByte </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Long</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">,</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">lpWideCharStr </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Long</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">,</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">ByVal</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#004ed0;">cchWideChar </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Long</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#333333;">)</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">As</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#006fe0;"> </span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">Long</span></p>
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a name="urvanov-syntax-highlighter-64fa30b77f4fd487876650-5"></a><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#000000;">#</span><span style=" font-family:'inherit'; font-size:7.8pt; font-weight:496; color:#800080;">EndIf</span></p></td></tr></table>
<p style=" margin-top:0px; margin-bottom:30px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a name="aswift_3_host"></a><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt;">Ф</span><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt;">ункция из примера используется для </span><a href="https://vremya-ne-zhdet.ru/vba-excel/smena-kodirovki/"><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt; text-decoration: underline; color:#0000ff;">преобразования кодировки</span></a><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt;"> UTF-8 в Windows-1251.</span></p>
<p style=" margin-top:0px; margin-bottom:30px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a name="Primecanie"></a><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt; font-weight:600;">П</span><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt; font-weight:600;">римечание</span></p>
<p style=" margin-top:0px; margin-bottom:30px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt;">Пакеты Office 2010, 2013 и 2016 по умолчанию устанавливаются в 32-разрядной версии, для установки 64-разрядной версии ее необходимо выбрать явно. Начиная с Office 2019 и Microsoft 365, по умолчанию устанавливается 64-разрядная версия.</span></p>
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'MS Shell Dlg 2'; font-size:7.8pt;"><br /></span></p></body></html>